//
//  FriendSelViewController.h
//  FootPrint
//
//  Created by alex tao on 4/9/13.
//  Copyright (c) 2013 alex tao. All rights reserved.
//

#import <UIKit/UIKit.h>
#import "FriendParser.h"

@protocol FriendSelDelegate <NSObject>

@optional
- (BOOL)willUpdateFriendSel:(NSMutableArray*)newSelFriends groupSel:(NSMutableArray*)selGroup;
- (void)didUpdateFriendSel:(NSMutableArray*)newSelFriends groupSel:(NSMutableArray*)selGroup;

@end


//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

@interface FriendSelViewController : UIViewController <FriendDelegate> {
    
    FriendParser *          _parser;
    
}


@property (assign, nonatomic) id<FriendSelDelegate>     selDelegate;
@property (retain, nonatomic) NSArray *     allFriends;
@property (retain, nonatomic) NSArray *     allGroup;
@property (retain, nonatomic) IBOutlet UITableView *friendTable;
@property (retain, nonatomic) IBOutlet UISegmentedControl *segmentControl;

@property (copy, nonatomic) NSMutableArray *  selFriends;
@property (retain, nonatomic) NSArray *       excludeFriends;
@property (copy, nonatomic) NSMutableArray *  selGroup;

- (IBAction)exit:(id)sender;
- (IBAction)okSelect:(id)sender;
- (IBAction)changeSegment:(id)sender;

@end
